package com.arpa.wms.handler;


import com.arpa.wms.cache.CarrierCache;
import com.arpa.wms.cache.ShopCache;
import com.arpa.wms.domain.dto.AuthDto;
import com.arpa.wms.domain.entity.Shop;
import com.arpa.wms.mapper.ShopMapper;
import lombok.extern.log4j.Log4j2;

import javax.annotation.Resource;

/**
 * 数据导出任务处理
 *
 * @author leo
 */
@Log4j2
public abstract class AbstractTokenManagerHandler {

    public static final String  DYXD_TOKEN_MANAGER = "DYXD";
    public static final String  DY_TOKEN_MANAGER = "DY";
    public static final String  PDD_TOKEN_MANAGER = "PDD";
    public static final String  KS_TOKEN_MANAGER = "KS";
    public static final String  KUAI_SHOU_TOKEN_MANAGER = "KUAI_SHOU";

    @Resource
    public ShopMapper shopMapper;

    @Resource
    public CarrierCache carrierCache;
    @Resource
    public ShopCache shopCache;
    /**
     * 刷新token
     *
     * @param shop 店铺信息
     * @return 处理结果
     */
    abstract public void refreshToken(Shop shop);

    /**
     * 获取token
     * @author liuxr
     * @date 2021/10/25 17:19
     * @param dto
     */
    abstract public void getToken(AuthDto dto);

}
